import 'package:flutter/material.dart';
import 'package:get/get.dart';
import 'package:robotcontrol/page/video_page/video_detail_page.dart';

class GetMaterialAppWidget extends StatefulWidget{
  final Widget widget;

  GetMaterialAppWidget({Key key,this.widget}):super(key: key);

  @override
  State<StatefulWidget> createState() {
   return _GetMaterialAppWidgetState();
  }
}
class _GetMaterialAppWidgetState extends State<GetMaterialAppWidget>{
  @override
  Widget build(BuildContext context) {
    // return MaterialApp(
    //   title: "APP",
    //   initialRoute: "/",
    //   routes: {
    //     "/":(BuildContext context) => widget.widget,
    //   },
    // );
    return GetMaterialApp(
      title: "APP",
      initialRoute: "/",
      getPages: [
        GetPage(name:"/",page: ()=> widget.widget),
        GetPage(name: "/videoDetail", page:()=> VideoDetailPage())
      ],
    );
  }

}